<template>
  <div>
    <van-nav-bar 
    fixed=true 
    placeholder=true
    title="设置" left-text="" left-arrow @click-left="onClickFanHui">
    </van-nav-bar>
    <van-cell title="个人资料设置" is-link to="/mysetting" />
    <van-cell title="地址管理" is-link to="/addresslist" />
    <van-cell title="账号与安全" is-link to="/accountsetting" />
  </div>
</template>

<script>
export default {
  data() {
    return {
      url: "",
      name: "",
      show: false,
    };
  },
  created() {
    this.axios({
      method: "GET",
      url: "/aapi/gerenzhuye",
    })
      .then((response) => {
        this.url = response.data.url;
        this.name = response.data.name;
      })
      .catch((error) => {
        console.log("123456");
        if (error.response.status === 401) alert("未登录，请进行登录");
        this.$router.push("/login");
      });
  },
  methods: {
    onClickFanHui() {
      this.$router.push("/gerenzhuye");
    },
  },
};
</script>

<style lang="less">
.van-cell {
  text-align: left;
}
</style>
